<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<jsp:useBean id="browse" class="bean.BrowseBean" scope="page" />
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<script type="text/javascript">
	//this will get called when the link is clicked
	function checkDeleteItem() {
	   //show the confirmation box
	   return confirm('Are you sure you want to delete this?');    
	}
</script>
<title>Browse Pub List</title>
</head>
<body>

<%
if(session.getAttribute("username") != null && session.getAttribute("username") != "") {
%>

<a href="logout.jsp">Logout</a>

<h1>Pub List</h1>

<div style="color:green">${dbmessage}</div>

<%=browse.getResult()%>
<%
}
else {
	out.println("<h1>Session expired!</h1>");
	out.println("<a href='http://localhost:8080/Pub2SearchAdmin/login.jsp'>Go to login page</a>");
}
%>

</body>
</html>